GET MEMBLOCK FROM OBJECT

This command will extra any memblock that has been previously added to the object using the ADD MEMBLOCK TO OBJECT command.

  Syntax
GET MEMBLOCK FROM OBJECT memblock Number, Object Number
  Parameters
memblock Number
Integer
The memblock number
Object Number
Integer
The object number

  Returns

This command does not return a value.

  Description

The memblock is not a representation of the object, it is an additional block of data that has been previously appended to the object through a built-in custom data feature.

  Example Code
input "(c)reate or (l)oad?";a$
if a$="c"
make object sphere 1,100
scale object 1,25,100,25
make memblock 1,12
write memblock dword 1,0,25
write memblock dword 1,4,100
write memblock dword 1,8,25
add memblock to object 1,1
f$="scaledobject.dbo"
if file exist(f$)=1 then delete file f$
save object f$,1
delete object 1
endif
load object "scaledobject.dbo",1
get memblock from object 1,1
sx#=memblock dword(1,0)
sy#=memblock dword(1,4)
sz#=memblock dword(1,8)
scale object 1,sx#,sy#,sz#
delete memblock from object 1
wait key
end
  See also

BASIC3D Commands Menu
Index